/**
 * 
 */

/**
 * @author Trunghpb
 *
 */

import java.awt.*;


import javax.swing.*;
import java.awt.event.*;

public class CenteredFrame extends JFrame {
	public CenteredFrame(){
		Toolkit kit = Toolkit.getDefaultToolkit();
		Dimension dimen = kit.getScreenSize();
		
		int screenHeight = dimen.height;
		int screenWidth = dimen.width;
		
		this.setSize(screenWidth / 2, screenHeight / 2);
		this.setLocation(screenWidth / 4, screenHeight / 4);
		
		Image img = kit.getImage("rsc/image/folders.gif");
		
		this.setIconImage(img);
		this.setTitle("Centered Frame");
	}
}
